package cn.tedu.medicalpath.role.service.impl;

import cn.tedu.medicalpath.employee.mapper.AuthorityListMapper;
import cn.tedu.medicalpath.employee.pojo.entity.AuthorityList;
import cn.tedu.medicalpath.employee.pojo.vo.AuthorityListVO;
import cn.tedu.medicalpath.role.mapper.ModuleInfoMapper;
import cn.tedu.medicalpath.role.mapper.RoleMapper;
import cn.tedu.medicalpath.role.pojo.dto.RoleQuery;
import cn.tedu.medicalpath.role.pojo.dto.RoleSaveParam;
import cn.tedu.medicalpath.role.pojo.entity.ModuleInfo;
import cn.tedu.medicalpath.role.pojo.entity.Role;
import cn.tedu.medicalpath.role.pojo.vo.ModuleInfoVO;
import cn.tedu.medicalpath.role.pojo.vo.RoleVO;
import cn.tedu.medicalpath.role.service.ModuleInfoService;
import cn.tedu.medicalpath.role.service.RoleService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Date;
import java.util.List;

@Service
@Slf4j
public class ModuleInfoServiceImpl implements ModuleInfoService {

    @Autowired
    private ModuleInfoMapper moduleInfoMapper;


    @Override
    public String[] select() {
        List<ModuleInfoVO> list = moduleInfoMapper.select();
        String [] moduleTitleArr = new String[list.size()];
        int count = 0;
        for (ModuleInfoVO moduleInfoVO : list){
            moduleTitleArr[count] = moduleInfoVO.getModuleDescription();
            count++;
        }
        return moduleTitleArr;
    }
}